
import java.awt.Color;
import java.awt.Font;

import javax.swing.JFrame;

import mathml.swing.JMathComponent;

public class MathMLTest {
    
    public static void main(String args[]) {
        JFrame frame = new JFrame();
        JMathComponent math = new JMathComponent();
        
        math.setBackground(Color.white);
        math.setFont(new Font("miscfixed", 0, 16));
        math.setContent("<math xmlns=\"http://www.w3.org/1998/Math/MathML\"><mstyle displaystyle=\"true\"><mfrac><mi>d</mi><mrow><mi>d</mi><mi>x</mi></mrow></mfrac><mrow><msubsup><mo>&#8747;</mo><mi>a</mi><mi>x</mi></msubsup></mrow><mi>f</mi><mrow><mo>(</mo><mi>t</mi><mo>)</mo></mrow><mi>d</mi><mi>t</mi><mo>=</mo><mi>f</mi><mrow><mo>(</mo><mi>x</mi><mo>)</mo></mrow></mstyle></math> ");
        
        frame.getContentPane().add(math);
        frame.setBounds(100, 100, 1000, 600);
        frame.setVisible(true);
    }
}
